package
{
	import flash.geom.Point;
	import flash.geom.Rectangle;
	
	import mx.graphics.BitmapFill;
	import mx.skins.ProgrammaticSkin;

	public class RepeatBackground extends ProgrammaticSkin 
	{
		public function RepeatBackground()
		{
			
		}
		override protected function updateDisplayList(w:Number, h:Number):void { 
			super.updateDisplayList(w,h); 
			graphics.clear();
			var b:BitmapFill = new BitmapFill(); 
			b.source = getStyle("backgroundImage");
			var p:Point = new Point(0,0);
			b.begin(graphics,new Rectangle(0,0,w,h),p); 
			graphics.drawRect(0,0,w,h); 
			b.end(graphics); 
		}
	}
}